package cn.iocoder.yudao.module.game.dal.mysql.gameHistory;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.game.dal.dataobject.gameHistory.GameHistoryDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.game.controller.admin.gameHistory.vo.*;

/**
 * 游戏日志 Mapper
 *
 * @author 芋道源码
 */
@Mapper
public interface GameHistoryMapper extends BaseMapperX<GameHistoryDO> {

    default PageResult<GameHistoryDO> selectPage(GameHistoryPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<GameHistoryDO>()
                .eqIfPresent(GameHistoryDO::getMemberId, reqVO.getMemberId())
                .orderByDesc(GameHistoryDO::getUpdateTime));
    }

}